Instruction different conditions files template

-----------------------------------------------------------

To use the sample, you need to replace the specified filepaths in the template file by the filepaths for your conditions files.
First, go into the routine "conditions_file_selection".
Now, go into the code component called "Selection_option" and under "End Routine" you find the filepaths to the sample conditions files. 
Replace them with the filepaths that lead to your conditions files.
Keep in mind, that the filepaths need to start from the position of your PsychoPy experiment.

If you want to keep it easy, store the new conditions files in the folder "conditionsfiles". 
Since that one is already in the specified filepaths, you would just need to change the name of the actual file in the code component. 

To add an option (e.g. if you have five conditions files), copy one of the "elif"-conditions, e.g:

elif key_resp.keys == "4":
    filepath_selected_conditions_file = "conditionsfiles/Conditions_file_4.xlsx" .

Then, insert that code snippet under the already existing code.

Then, change the condition (elif key_resp.keys == "4") by changing the number to whatever key you want to use to select the new option. 
For example, if you want to select the new option to be selected when you press "5", you need to replace "4" by "5".
Also, replace the filepath with the filepath that leads to the new conditions file.
For example, if your fifth, new conditions file's filepath is  "conditionsfiles/Conditions_file_5.xlsx", use that to replace "conditionsfiles/Conditions_file_4.xlsx".

The result should look like this:

elif key_resp.keys == "5":
    filepath_selected_conditions_file = "conditionsfiles/Conditions_file_4.xlsx"

To keep it easy for you, also change the textbox "Display_Options" by listing the new option, too. 
To do that, add something like "For number 5, press 5" below the text that already exists in "Display_Options".

To delete an option (if you e.g. only have three conditions files), just delete a elif-condition and also delete the option from the list in "Display_Options".

That's it!

--------------------------------------------------------------

If you have any questions regarding the usage of the template file or if you have constructive criticism on how to improve these instructions, please message one of the email addresses listed for PsychoPy support in the Gitlab of the PsychoPy workshop. Thank you!